//
// Created by Mengyu Li on 2021/4/21.
//

import Foundation

public extension String {
    func range(from nsRange: NSRange) -> Range<Index>? {
        Range(nsRange, in: self)
    }

    func nsRange(from range: Range<Index>) -> NSRange {
        NSRange(range, in: self)
    }
}
